<!DOCTYPE html>
<html lang="pt_BR">
<head>
	<?=$this->headTitle()?>
	<meta name="description" content="<?php echo $this->description?>" />
<meta name="keywords" content="<?php echo $this->keywords?>" />
	<?=$this->headMeta(); ?> 
	<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
	<?=$this->headLink()?>
</head>

<body>
	<?php if ($this->logado) { ?>
	<div role="navigation" class="navbar navbar-default navbar-static-top">
		<div class="container">
			<div class="navbar-header">
				<button data-target=".navbar-collapse" data-toggle="collapse"
					class="navbar-toggle" type="button">
					<span class="sr-only">Toggle navigation</span> <span
						class="icon-bar"></span> <span class="icon-bar"></span> <span
						class="icon-bar"></span>
				</button>
				<a href="/" class="navbar-brand">EJC BR</a>
			</div>
			<div class="navbar-collapse collapse">
				<ul class="nav navbar-nav">
					<li class="<?=($this->pagMenu == ""?"active":"")?>"><a href="/">Home</a></li>
					<?php if(Application_Plugin_Auth::_exibeReferencia('usuario', 'index')){ ?>
					<li class="dropdown <?=($this->pagMenu == "usuario"?"active":"")?>">
						<a data-toggle="dropdown" class="dropdown-toggle" href="#">Usuários <b class="caret"></b></a>
						<ul class="dropdown-menu">
							<li><a href="/usuario/">Listar</a></li>
							<li><a href="/usuario/adicionar/">Adicionar</a></li>
						</ul>
					</li>
					<?php } ?>
					<?php if(Application_Plugin_Auth::_exibeReferencia('paroquia', 'index')){ ?>
					<li class="dropdown <?=($this->pagMenu == "paroquia"?"active":"")?>">
						<a data-toggle="dropdown" class="dropdown-toggle" href="#">Paróquias <b class="caret"></b></a>
						<ul class="dropdown-menu">
							<li><a href="/paroquia/">Listar</a></li>
							<li><a href="/paroquia/adicionar/">Adicionar</a></li>
						</ul>
					</li>
					<?php }elseif(Application_Plugin_Auth::_exibeReferencia('paroquia', 'minha-paroquia')){ ?>
					<li class="<?=($this->pagMenu == "paroquia"?"active":"")?>"><a href="/paroquia/minha-paroquia/">Minha paróquia</a></li>
					<?php }?>
					<?php if(Application_Plugin_Auth::_exibeReferencia('encontro', 'index')){ ?>
					<li class="dropdown <?=($this->pagMenu == "encontro"?"active":"")?>">
						<a data-toggle="dropdown" class="dropdown-toggle" href="#">Encontros <b class="caret"></b></a>
						<ul class="dropdown-menu">
							<li><a href="/encontro/">Listar</a></li>
							<li><a href="/encontro/adicionar/">Adicionar</a></li>
						</ul>
					</li>
					<?php } ?>
				</ul>
				<ul class="nav navbar-nav navbar-right">
					<li><a href="<?=$this->url(array('controller' => '', 'action' => 'logout'), null, true);?>">Sair</a></li>
				</ul>
			</div>
			<!--/.nav-collapse -->
		</div>
	</div>
				<?php } ?>
	

	<?php echo $this->layout()->content?>

	<!-- /container --> 
	<?=$this->headScript()?> 
</body>
</html>